package com.mini.vo;


import com.fasterxml.jackson.annotation.JsonFormat;

import java.util.Date;
import java.util.List;


public class PageResultWithCountVO<T> extends PageResultVO {

    private static final long serialVersionUID = -6751407410202208269L;
    private T totalRecord;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm", timezone = "GMT+8")
    private Date latestUpdateTime;

    public PageResultWithCountVO() {
    }

    public PageResultWithCountVO(long total, List<T> rows, T totalRecord) {
        super(total, rows);
        this.totalRecord = totalRecord;
    }

    public PageResultWithCountVO(long total, List<T> rows, T totalRecord, Date latestUpdateTime) {
        super(total, rows);
        this.totalRecord = totalRecord;
        this.latestUpdateTime = latestUpdateTime;
    }


    public T getTotalRecord() {
        return totalRecord;
    }

    public void setTotalRecord(T totalRecord) {
        this.totalRecord = totalRecord;
    }

    public Date getLatestUpdateTime() {
        return latestUpdateTime;
    }

    public void setLatestUpdateTime(Date latestUpdateTime) {
        this.latestUpdateTime = latestUpdateTime;
    }
}
